mce: Add a x86_mcinfo_reserve() function, to reserve space from mc_info.
authorKeir Fraser <keir.fraser@citrix.com>
Mon, 19 Apr 2010 07:55:33 +0000 (08:55 +0100)
committerKeir Fraser <keir.fraser@citrix.com>
Mon, 19 Apr 2010 07:55:33 +0000 (08:55 +0100)
commitb17520fdb15fb3e2c7b3456cfb55d32fc58653dc
tree36caf72ff7c5d7adb31fd868494437b01207e993
parent05dd855d25a97c11c775ac8a8e61c9ddaa45ab64
mce: Add a x86_mcinfo_reserve() function, to reserve space from mc_info.

With this method, we don't need to collect bank and globalinformation
to a local variable and do x86_mcinfo_add() to copy that information
to mc_info.  This avoid copy and also we can be aware earlier if there
is enough space in the mc_info.

Also extract function that get global/bank information to seperated
function mca_init_bank/mca_init_global.

It's meaningless to get the current information in mce context, keep
it here but should be removed in future.

Also a flag added to mc_info, to indicate some information is lost due
to OOM.

Signed-off-by: Jiang, Yunhong <yunhong.jiang@intel.com>
xen/arch/x86/cpu/mcheck/mce.c
xen/arch/x86/cpu/mcheck/mce.h
xen/include/public/arch-x86/xen-mca.h